<template>
    <div>
      <div class="app-container">
        <el-col :span="12">
          以下内容是接口返回的：<br/><br/><br/>
          {{content}}
        </el-col>
      </div>
    </div>
  </template>
  
  <script>
    import {testFunction} from '@/api/test'
    export default {
      created() {
        this.getData();
      },
      name: 'test',
      data() {
        return {
            content: ''
        }
      },
      methods: {
        getData() {
            let that = this;
            testFunction().then(response=>{
                that.content = response.data
            });
        }
      },
    }
  </script>
  
  <style scoped>
    .app-container {
      width: 80%;
      margin: 120px auto;
    }
  
    .img-style {
      width: auto;
      height: auto;
      max-width: 100%;
      max-height: 100%;
    }
  </style>
  